package com.ews.onlineexchange.model.assess;

import java.util.ArrayList;
import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.OneToMany;

import com.ews.onlineexchange.model.DataEntity;

@Entity
public class AssessClass extends DataEntity {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	private String name;
	private boolean allowSupplierApply;
	private List<Dict> dicts = new ArrayList<>();

	@Column( unique = true )
	public String getName() {
		return name;
	}

	public void setName( String name ) {
		this.name = name;
	}

	public boolean isAllowSupplierApply() {
		return allowSupplierApply;
	}

	public void setAllowSupplierApply( boolean allowSupplierApply ) {
		this.allowSupplierApply = allowSupplierApply;
	}

	@OneToMany( mappedBy = "assessClass" )
	public List<Dict> getDicts() {
		return dicts;
	}

	public void setDicts( List<Dict> dicts ) {
		this.dicts = dicts;
	}

}
